class SidebarView {
    constructor() {
        this.jqObj = $("#sidebar");
        this.contentObj = $("#sidebarContent");
        this.isShown = false;
        $("#sidebar").html(SidebarView.INIT_HTML);
        $(".toolbar-open").click(() => {
            this.toggleSidebar();
        })
    }
    getJqObjOfContentDiv() {
        return this.contentObj;
    }
    toggleSidebar() {
        if (this.isShown) {
            this.jqObj.animate({right: -SidebarView.MOVE_DISTANCE});
            this.isShown = false;
        } else {
            this.jqObj.animate({right: 0});
            this.isShown = true;
        }
    }
}
SidebarView.INIT_HTML = `
<div class="sidebar-tabs">
      <div class="toolbar-tabs-middle">
          <span class="toolbar-tabs-middle-text toolbar-open">商家评论</span>
      </div>
</div>
<div id="sidebarContent" class="sidebar-content"></div>`;
SidebarView.MOVE_DISTANCE = 295;